package marchsoft.utils;

import org.springframework.security.core.userdetails.UserDetailsService;
import org.springframework.stereotype.Component;

/**
 * @ClassName UserDetailsServiceProvider
 * @Author ZhuGuangLiang <786945363@qq.com>
 * @Date 2021/11/30 11:15
 */
@Component
public class UserDetailsServiceProvider {
	UserDetailsService getUserDetailsService(String type) {
		if (("FRONT").equals(type)) {
			return SpringContextHolder.getBean("frontUserDetail");
		}
		return SpringContextHolder.getBean("userDetailsService");
	}
}
